1. Field of the Invention
This invention relates generally to digital controllers known variably as sequencers or state machines, and more particularly to single-chip programmable digital controllers.
2. Description of the Related Art
State machines are digital devices which develop predetermined outputs dependent both upon its current "state" and upon its inputs. A typical state machine includes input combinatorial logic, a state register for storing the current state of the machine, and output registered and/or combinatorial logic responsive to the state register. State machines often utilize extensive feedback from the state register and output combinatorial and/or registered logic to the input combinatorial logic to create complex logic states.
Traditionally, state machines were designed using discrete digital gates for the input and output combinatorial logic, and flip-flops (such as D-type flip-flops) for the state registers. As designers created increasingly complex state machines, discrete logic elements were replaced with integrated logic elements such as read only memories (ROMs) and programmable logic arrays (PLAs), and the discrete flip-flops were replaced with integrated digital registers.
State machines are often used as local control units for a subsystem within a larger digital system. By providing a number of microprogrammed control units within a digital system, the demands on the central processing unit (CPU) are reduced with a subsequent increase in system performance. Typical applications for microprogrammed control units are in arithmetic logic units (ALUs), I/O units, interrupt units, diagnostic units, and bus control units.
As mentioned previously, a state machine being used as a microprogrammed control unit includes, at the very least, a state register and some form of digital logic. The simplest of microprogrammable control units uses a ROM which is directly addressed by the output of the state register. The ROM can store a sequence of microinstruction code words, each of which may be divided into a control field and a microinstruction field. The control field can be used to develop outputs to control a unit within a digital system, and the internal microinstruction field can be clocked into the state register to become the ROM address for the next state. ROM based control units are quite primitive, and do not have the capability of conditional branching, subroutine calls, etc.
More advanced microprogrammable controllers have been designed which replace the simple state register with sophisticated address sequencers. Address sequencers can reduce the width of an associated ROM because a short microinstruction code can be used which, when decoded, determines the address of the next microinstruction code.
One such microprogrammable controller, known as the AM2910, is produced in integrated form by Advanced Micro Devices, Inc. of Sunnyvale, Calif. The AM2910 controls the execution sequence of microinstructions stored in an external storage device such as ROM or programmable ROM (PROM). The AM2910 provides a 12 bit address from one of four sources including a microprogram address counter-register, an external input, a loop counter, and a stack register. A 12 bit address bus allows the AM2910 to address a 4K external memory device.
To make digital systems smaller, faster, and less consumptive of energy it is desirable to integrate as many functions as possible into a single, integrated device. Advanced Micro Devices, Inc. produces a single chip fuse programmable controller (FPC) as part number AM29PL141 which allows implementation of complex state machines and controllers by programming an appropriate sequence of microinstructions. The AM29PL141 includes a repertoire of jumps, loops, and subroutine calls which can be conditionally executed based upon test inputs to the device, and provides a designer with powerful control-flow primitives. An on-board PROM can store 64 words of 32 bit wide microprogram memory, and an on-board microprogram address sequencer can execute 29 high level microinstructions.
The AM29PL141 is a great advance over prior art programmable controllers. However, the expansibility of the AM29PL141 is limited and expensive, and its I/O imposes certain design limitations. For example, the AM29PL141 lacks the capability of synchronizing its test and condition code inputs, which requires that the external test conditions need to be synchronized externally so as to remain stable during an entire micro-cycle period. Also, the AM29PL141 lacks the capability of dynamically altering its control outputs, and can only be horizontally cascaded with similar programmable controllers.
Most prior art programmable controllers, including the AM2910 and the AM29PL141 use ROMs or PROMs to store their microinstructions. If, for example, the internal PROM of an AM29PL141 has been programmed, its contents cannot later be changed.
For certain applications, however, it is desirable to implement a programmable controller having memory which can be dynamically altered. This, of course, implies some type of read/write memory such as random access memory (RAM), erasable PROM (EPROM) electrically erasable PROM (EEPROM), or bubble memory. However, the addition of read/write memory to a programmable controller increases the complexity of the I/O to the device. Heretobefore, the complexities involved with implementing a programmable controller with read/write memory have discouraged integrated circuit designers from attempting such a task.